package com.kuaiprint.fragment;

import android.content.Intent;
import android.os.Bundle;
import android.support.v4.app.Fragment;
import android.view.LayoutInflater;
import android.view.View;
import android.view.View.OnClickListener;
import android.view.ViewGroup;
import android.widget.RelativeLayout;
import android.widget.TextView;

import com.kuaiprint.main.MainActivity;
import com.kuaiprint.main.R;
import com.kuaiprint.main.RegisterActivity;
import com.kuaiprint.main.SubmitActivity;
import com.kuaiprint.main.UserHelperActivity;
import com.kuaiprint.main.UserMessageActivity;

public class UserCenterFragment extends Fragment{
	
	private RelativeLayout userHelp;
	private TextView userSubmit;
	private TextView userRegister;
	private RelativeLayout userMessage;
	
	
	
	@Override
	public View onCreateView(LayoutInflater inflater, ViewGroup container,  
            Bundle savedInstanceState)  
    {  
        View view = inflater.inflate(R.layout.usercenter_fragment, container, false);
        userHelp = (RelativeLayout) view.findViewById(R.id.user_help_layout);
        userHelp.setOnClickListener(new OnClickListener() {
			
			@Override
			public void onClick(View v) {
				// TODO Auto-generated method stub
				Intent intent =new Intent();
				intent.setClass(getActivity(), UserHelperActivity.class);
				startActivity(intent);
			}
		});
        userMessage = (RelativeLayout) view.findViewById(R.id.user_message);
        userMessage.setOnClickListener(new OnClickListener() {
			
			@Override
			public void onClick(View v) {
				// TODO Auto-generated method stub
			
				Intent intent =new Intent();
				intent.setClass(getActivity(), UserMessageActivity.class);
				startActivity(intent);
			}
		});
        userSubmit = (TextView) view.findViewById(R.id.user_submit);
        userSubmit.setOnClickListener(new OnClickListener() {
			
			@Override
			public void onClick(View v) {
				// TODO Auto-generated method stub
				Intent intent =new Intent();
				intent.setClass(getActivity(), SubmitActivity.class);
				startActivity(intent);
			}
		});
        userRegister = (TextView) view.findViewById(R.id.user_register);
        userRegister.setOnClickListener(new OnClickListener() {
			
			@Override
			public void onClick(View v) {
				// TODO Auto-generated method stub
				Intent intent =new Intent();
				intent.setClass(getActivity(), RegisterActivity.class);
				startActivity(intent);
			}
		});
        
        
        
        
		return view;  
        }
}
